# TODO multi-folders ?
# SUBDIRS = core common media tools entities/character/ entities/bodyparts/ items items/clothes db input globals tools


bin_PROGRAMS = $(top_srcdir)/rods

# Use right g++ flags.
__top_srcdir__rods_CPPFLAGS = -W -Wall -Wextra -pedantic	 		\
-Wfloat-equal -Wcast-qual -Wcast-align -Wunreachable-code -Wundef		\
-Wpointer-arith -Wmissing-declarations -Wmissing-braces -Wparentheses 		\
-O0 -DDEBUG -g -DZERMINGORE #-DMESA_DEBUG=1 #-DDEBUG_SOUND

# release:
#  -s -02
# -O3 -DNDEBUG
# -Wshadow
# -Wformat (check printf args)
# -Wwrite-strings (check const strings)


__top_srcdir__rods_CPPFLAGS += ${libglfw_CFLAGS} ${GLEW_CFLAGS} ${OPENAL_CFLAGS} ${IMAGE_MAGICK_CFLAGS}
__top_srcdir__rods_LDADD = ${libglfw_LIBS} ${GLEW_LIBS} ${OPENAL_LIBS} ${LIBPQXX_LIBS} ${IMAGE_MAGICK_LIBS}

__top_srcdir__rods_SOURCES =	\
main.cc					\
\
common/Object.cc		\
\
core/Context.cc			\
core/Game.cc			\
core/Scene.cc			\
core/GraphicEngine.cc	\
\
graphics/Texture.cc		\
graphics/TextureManager.cc	\
graphics/Skybox.cc		\
graphics/Light.cc		\
graphics/DirectionalLight.cc	\
\
db/DBManager.cc			\
db/DBInventory.cc		\
\
entities/character/Character.cc	\
entities/bodyparts/BodyPart.cc	\
\
globals/keys.c			\
globals/engines.cc		\
\
input/Input.cc			\
input/InputCharacter.cc		\
\
items/Item.cc			\
items/clothes/Cloth.cc		\
\
media/Shader.cc			\
media/Sound.cc			\
\
tools/Vector.cc			\
tools/Matrix.cc			\
\
tools/debug_funs.cc


# if -DDEBUG __top_srcdir__rods_SOURCES += tools/debug_funs

# models/Cube.cc
# models/Shape2D.cc
